package com.chainofresponsibility.pattern.service;

import java.util.Date;
import java.util.Map;
import java.util.concurrent.ConcurrentHashMap;

/**
 * @author cc
 * @classname AuditService
 * @description TODO
 * @date 2022/3/29 15:34
 */
public class AuditService {

    private static Map<String, Date> auditMap = new ConcurrentHashMap<>();

    public static Date queryAuditInfo(String uid, String orderId) {
        return auditMap.get(uid.concat(orderId));
    }

    public static void audit(String uid, String orderId) {
        auditMap.put(uid.concat(orderId), new Date());
    }
}
